<!DOCTYPE html>
<html>
<head>
    <meta name="layout" content="main2"/>
    <g:set var="entityName"
    value="${message(code: 'workflowStage.label', default: 'workflowStage')}"/>
    <title>新增工作流阶段</title>
</head>

<body>
    <div class="main-body">
        <div class="page-wrapper">
            <div class="page-header">
                <div class="page-header-title">
                    <h4>新增工作流阶段</h4>
                </div>
                <div class="page-header-breadcrumb">
                    <ul class="breadcrumb-title">
                        <li class="breadcrumb-item">
                            <a href="/salesDashboard/index">
                                <i class="icofont icofont-home"></i>
                            </a>
                        </li>
                        <li class="breadcrumb-item">
                            <g:link controller="workflow" action="show" id="${this.workflowStage?.workflow?.id}">工作流</g:link>
                        </li>
                        <li class="breadcrumb-item">新增工作流阶段</li>
                    </ul>
                </div>
            </div>
            <div class="page-body">
                <g:if test="${flash.message}">
                <div class="message" role="status">${flash.message}</div>
            </g:if>
            <g:hasErrors bean="${this.workflowStage}">
            <ul class="errors" role="alert">
                <g:eachError bean="${this.workflowStage}" var="error">
                <li <g:if test="${error in org.springframework.validation.FieldError}">data-field-id="${error.field}"</g:if>><g:message
                    error="${error}"/></li>
                </g:eachError>
            </ul>
        </g:hasErrors>
        <div class="card">
            <div class="card-header">
                <h5>新增工作流阶段</h5>
                <div class="card-header-right">
                    <i class="icofont icofont-rounded-down"></i>
                </div>
            </div>
            <div class="card-block">
                <g:form action="save" class="form-horizontal">
                
                <div class="form-group row">
                    <g:textField name="workflow.id" required="required" id="workflow"
                    value="${this.workflowStage?.workflow?.id}" class="hide"/>

                    <label class="col-md-2 control-label">名称</label>

                    <div class="col-md-3">
                        <g:textField name="name"
                        value="${this.workflowStage?.name}"
                        class="form-control"/>
                    </div>
                    <label class="col-md-2 control-label">执行次序</label>

                    <div class="col-md-3">
                        <g:textField name="executionSequence"
                        value="${this.workflowStage?.executionSequence}"
                        class="form-control"/>
                    </div>

                </div>

                <div class="form-group row">

                    <label class="col-md-2 control-label">能否退回</label>

                    <div class="col-md-3">
                        <div class="radio radio-info radio-inline">
                            <input type="radio" name="canReject" value="true" checked="">
                            <label for="radio1">true</label>
                        </div>

                        <div class="radio radio-info radio-inline">
                            <input type="radio" name="canReject" value="false">
                            <label for="radio2">false</label>
                        </div>
                    </div>
                </div>

                <div class="form-group row">
                    <div class="col-md-12">
                        <g:submitButton class="btn btn-info" id="btn" name="update" value="保存"/>
                    </div>
                </div>
            </g:form>
        </div>
    </div>
</div>
</div>
</div>

</body>
</html>
